﻿CREATE PROCEDURE [dbo].[yaf_bannedip_list](
                @BoardID INT,
                @ID      INT  = NULL)
AS
    BEGIN
        IF @ID IS NULL
        SELECT *
        FROM   yaf_BannedIP
        WHERE  BoardID = @BoardID
        ELSE
        SELECT *
        FROM   yaf_BannedIP
        WHERE  BoardID = @BoardID
        AND ID = @ID
    END


